package com.rhino.xchat.http;

import android.text.TextUtils;

/**
 * @author LuoLin
 * @since Create on 2024/9/29.
 */
public enum ErrorCode {
    CODE_0000("0", "服务成功");

    private String code;
    private String msg;

    ErrorCode(String code, String msg) {
        this.code = code;
        this.msg = msg;
    }

    public String getCode() {
        return code;
    }

    public String getMsg() {
        return msg;
    }

    public static boolean isSuccess(String code) {
        return TextUtils.equals(code, CODE_0000.code);
    }
}
